<?php

	session_start();
	if(!isset($_SESSION['user'])) {
		$_SESSION['user'] = null;
	}
	
	require_once '/include/db.php';
	require_once '/include/user.php';
	require_once '/include/userconfig.php';
	require_once '/include/databasestat.php';
	//require_once 'auth.php';
	global $db;
	$db = new Database();
	$db->connect();
	
	$dbstat = new DbStat();
	//var_dump(date('YmdHms',time()-24*60*60));
	//var_dump($dbstat->getDuration(date('YmdHms',time()-24*60*60), date('YmdHms')));
	
	# define constant value
	define("ADMIN",    1);
	define("USER",     2);
	define("ENABLED",  111);
	define("DISABLED", 100);
	
	global $cur_time;
	$cur_time = 1302156819;
?>